<template>
  <div style="padding: 20px;background-color: white;">
          <el-row>
            <el-col :span="24">
              <div
                class="grid-content bg-purple-dark"
                style="background-color: #F6F6F6;padding: 10px;"
              >
                <b>基本信息</b>
              </div>
            </el-col>
          </el-row>
          <br />
          <el-row class="erow">
            <el-col :span="8">
              <div class="grid-content bg-purple">
                <b>所属单位：</b>
                {{carinfo.companyName}}
              </div>
            </el-col>
          </el-row>
          <br />
          <br />
          <el-row class="erow">
            <el-col :span="6">
              <div class="grid-content bg-purple">
                <b>车牌号：</b>
                {{carinfo.carCode}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>车辆属性:</b>
                {{carinfo.useType}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>品牌型号:</b>
                {{carinfo.pinpai}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>车辆型号:</b>
                {{carinfo.carModel}}
              </div>
            </el-col>
          </el-row>
          <br />
          <br />
          <el-row class="erow">
            <el-col :span="6">
              <div class="grid-content bg-purple">
                <b>车辆类型：</b>
                {{carinfo.carType}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>车辆种类：</b>
                {{carinfo.dlclass}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>车架号：</b>
                {{carinfo.fromCode}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>排量：</b>
                {{carinfo.discharge}}{{carinfo.dischargeUtil}}
              </div>
            </el-col>
          </el-row>
          <br />
          <br />
          <el-row class="erow">
            <el-col :span="6">
              <div class="grid-content bg-purple">
                <b>座位数：</b>
                {{carinfo.zuowei}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>排放标准：</b>
                {{carinfo.paiFang}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>发动机号：</b>
                {{carinfo.machineCode}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>购买价格：</b>
                {{carinfo.buyPrice}}
              </div>
            </el-col>
          </el-row>
          <br />
          <br />
          <el-row class="erow">
            <el-col :span="6">
              <div class="grid-content bg-purple">
                <b>车辆颜色：</b>
                {{carinfo.color}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>产地：</b>
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>经费来源：</b>
                {{carinfo.jingFei}}
              </div>
            </el-col>
            <el-col :span="6">
              <div class="grid-content bg-purple-light">
                <b>购置方式：</b>
                {{carinfo.type}}
              </div>
            </el-col>
          </el-row>
          <br />
          <br />
          <el-row class="erow">
            <el-col :span="24">
              <div class="grid-content bg-purple">
                <b>备注信息：</b>
                {{carinfo.remark}}
              </div>
            </el-col>
          </el-row>
          <br />
          <br />
          <br />
          <el-row>
            <el-col :span="24">
              <div
                class="grid-content bg-purple-dark"
                style="background-color: #F6F6F6;padding: 10px;"
              >
                <b>电子文本信息</b>
              </div>
            </el-col>
          </el-row>
          <br />
          <el-row class="erow">
            <el-col :span="5">
              <img style="width: 80%;" :src="carinfo.xszfileUrl" />
            </el-col>
            <el-col :span="5">
              <img style="width: 80%;" :src="carinfo.czzsfileUrl" />
            </el-col>
            <el-col :span="5">
              <img style="width: 80%;" :src="carinfo.zckpfileUrl" />
            </el-col>
            <el-col :span="5">
              <img style="width: 80%;" :src="carinfo.ysfpfileUrl" />
            </el-col>
            <el-col :span="4">
              <img style="width: 100%;" :src="carinfo.bshfileUrl" />
            </el-col>
          </el-row>
          <br />
          <el-row class="erow" style="text-align: center;">
            <el-col :span="5">
              <div class="grid-content bg-purple">行驶证</div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple-light">产权证书</div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple-light">资产卡片</div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple-light">原始发票或调拨单</div>
            </el-col>
            <el-col :span="4">
              <div class="grid-content bg-purple-light">标识化</div>
            </el-col>
          </el-row>
          <br />
        </div>
</template>

<script>
import { axios } from "@/api/axios";
export default {
  props: {
    carId: {
      type: Number,
      default: 0
    },
   
  },
  data: function() {
    return {
      carinfo: {},
      src: "",
    };
  },
  methods: {
    fetchData() {
      axios("/admin/car/findCar.do", "get", {
        carId: this.carId
      }).then(data => {
        this.carinfo = data.car;
 
      });
    },
  },
   
  created() {
    this.fetchData();
  }
};
</script>